{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "from home_robot.perception.detection.detic.detic_perception import DeticPerception\n",
    "from PIL import Image\n",
    "import numpy as np\n",
    "from detectron2.data.detection_utils import read_image\n",
    "from home_robot.perception.detection.detic.Detic.detic.predictor import VisualizationDemo\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "segmenter = DeticPerception(\n",
    "        config_file=None,\n",
    "        vocabulary=\"coco\",\n",
    "        custom_vocabulary=\"\",\n",
    "        checkpoint_file=None,\n",
    "        sem_gpu_id=0,\n",
    "        # verbose: bool = False,\n",
    "    )"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "path = \"/home/jaydv/Documents/ball.jpeg\"\n",
    "image = read_image(path,  format=\"BGR\")\n",
    "demo = VisualizationDemo()"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "data = {\"a\": 1, \"b\": 2, \"c\": 3}\n",
    "d = {}\n",
    "data['obs'] = [1,2,3,4,5]\n",
    "for key, value in data.items():\n",
    "    d[key] = value\n",
    "d"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "from home_robot.utils.config import get_config, load_config"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": [
    "get_config(\"../configs/parameters.yaml\")"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "home-robot",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.9.17"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
